import Mock from 'mockjs';


const List = [];
const count = 20;


for (let i = 0; i < count; i++) {
    List.push(Mock.mock({
        id: '@id',
        title: '@ctitle(10, 20)',
        'status|1': ['published', 'draft'],
        author: '@cname',
        displayTime: '@datetime',
        pageviews: '@integer(300, 5000)'
    }));
}

export default {
    getList: () => List,
    getArticle: () => ({
        id: 120000000001,
        author: { key: 'mockPan' },
        sourceName: '原创作者',
        categoryItem: [{ key: 'global', name: '全球' }],
        commentDisabled: false,
        content: '<p>我是测试数据我是测试数据</p><p><img class="wscnph" src="https://wpimg.wallstcn.com/4c69009c-0fd4-4153-b112-6cb53d1cf943" data-wscntype="image" data-wscnh="300" data-wscnw="400" data-mce-src="https://wpimg.wallstcn.com/4c69009c-0fd4-4153-b112-6cb53d1cf943"></p>"',
        contentShort: '我是测试数据',
        displayTime: +new Date(),
        imageUri: 'https://wpimg.wallstcn.com/e4558086-631c-425c-9430-56ffb46e70b3',
        platforms: ['a-platform'],
        sourcUri: 'https://github.com/PanJiaChen/vue-element-admin',
        status: 'published',
        tags: [],
        title: ''
    })
};
